Using Python Functions
From version 7.2, you can execute Python code or methods from a file.
For details on each of the functions, see Python Library Objects.
To test the Python functions:
|
1.
|
Download the sample project here. |
|
2.
|
Ensure that Python is installed on your system |
|
3.
|
Copy the files to C:\TEMP, |
|
4.
|
Update the project to use the correct Python path. In Business Entities > Instances, edit the Module Path in Python Parameters for Code - Modulepath to include your user in the path. For example, C:\Users\lynnkolber\AppData\Local\Programs\Python\Python38-32. This folder may be hidden in Windows. |
|
5.
|
The example includes a callout that you can use to test the functions. |
|
6.
|
For example, you can execute Python code in a .py file. |
|
7.
|
Run the project. A Quick callout appears. |
|
8.
|
Click Quick to open the callout. |
|
10.
|
In Business Entities, in the Properties tab, you can view the values of the various properties used. |
|
11.
|
Test the functions. For example, click Python code - Addition using .py file. |